package com.ourteam.system.dao;

import net.dao.BaseQueryBean;
import net.dao.BaseWhereCriterion;
import net.dao.IDataAccessInterface;

import org.apache.commons.lang.StringUtils;

import java.util.Arrays;
import java.util.List;
import java.util.Map;


/**
 * Template Name : DAO查询对象
 * Template Version : 1
 * Template Last Modfiy Date : Sat Aug 19 10:06:32 CST 2017
 * Auto Generate Date : 2018-07-31 15:13:34
  * Warning ! This file will be overwrite when regenerate !
  *
 */
public class SysUserPhotoDAOQueryBean extends BaseQueryBean {
    public SysUserPhotoDAOQueryBean() {
        super();
    }

    public SysUserPhotoDAOQueryBean(BaseQueryBean aQueryBean) {
        super(aQueryBean);
    }

    public SysUserPhotoDAOQueryBean(BaseQueryBean aQueryBean,
        Map tableReplaceMap) {
        super(aQueryBean, tableReplaceMap);
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();

        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }

        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        return new Criteria(this);
    }

    public void addIdSelectProperty() {
        addIdSelectProperty("id");
    }

    public void addIdSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysUserPhotoDAO.Id, aAlias);
        } else {
            addSelectProperty(ISysUserPhotoDAO.Id, "id");
        }
    }

    public void addUserIdSelectProperty() {
        addUserIdSelectProperty("userId");
    }

    public void addUserIdSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysUserPhotoDAO.UserId, aAlias);
        } else {
            addSelectProperty(ISysUserPhotoDAO.UserId, "userId");
        }
    }

    public void addUserPhotoSelectProperty() {
        addUserPhotoSelectProperty("userPhoto");
    }

    public void addUserPhotoSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysUserPhotoDAO.UserPhoto, aAlias);
        } else {
            addSelectProperty(ISysUserPhotoDAO.UserPhoto, "userPhoto");
        }
    }

    public void addAllSelectProperties() {
        addIdSelectProperty();

        addUserIdSelectProperty();

        addUserPhotoSelectProperty();
    }

    public static class Criteria extends BaseWhereCriterion<SysUserPhotoDAOQueryBean> {
        protected Criteria(SysUserPhotoDAOQueryBean aParentObject) {
            super(aParentObject);
        }

        public Criteria andIdIsNull() {
            addCriterion(ISysUserPhotoDAO.Id + " is null");

            return this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion(ISysUserPhotoDAO.Id + " is not null");

            return this;
        }

        public Criteria andIdIsNotEmpty() {
            addCriterion(ISysUserPhotoDAO.Id + " is not null AND " +
                ISysUserPhotoDAO.Id + " <> ''");

            return this;
        }

        public Criteria andIdIsEmpty() {
            addCriterion("(" + ISysUserPhotoDAO.Id + " is null OR " +
                ISysUserPhotoDAO.Id + " = '')");

            return this;
        }

        public Criteria andIdEqualTo(long value) {
            return andIdEqualTo(Long.valueOf(value));
        }

        public Criteria andIdEqualTo(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.Id + " = ", value, "id");

            return this;
        }

        public Criteria andIdEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.Id);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.Id + " = ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdNotEqualTo(long value) {
            return andIdNotEqualTo(Long.valueOf(value));
        }

        public Criteria andIdNotEqualTo(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.Id + " <>", value, "id");

            return this;
        }

        public Criteria andIdNotEqualToOrIsNull(long value) {
            return andIdNotEqualToOrIsNull(Long.valueOf(value));
        }

        public Criteria andIdNotEqualToOrIsNull(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.Id + " is null OR " +
                ISysUserPhotoDAO.Id + " <>", value, "id");

            return this;
        }

        public Criteria andIdNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.Id);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.Id + " <> ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdGreaterThan(long value) {
            return andIdGreaterThan(Long.valueOf(value));
        }

        public Criteria andIdGreaterThan(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.Id + " >", value, "id");

            return this;
        }

        public Criteria andIdGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.Id);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.Id + " > ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdGreaterThanOrEqualTo(long value) {
            return andIdGreaterThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andIdGreaterThanOrEqualTo(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.Id + " >=", value, "id");

            return this;
        }

        public Criteria andIdGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.Id);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdGreaterThanOrEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.Id + " >= ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdLessThan(long value) {
            return andIdLessThan(Long.valueOf(value));
        }

        public Criteria andIdLessThan(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.Id + " <", value, "id");

            return this;
        }

        public Criteria andIdLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.Id);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.Id + " < ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdLessThanOrEqualTo(long value) {
            return andIdLessThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andIdLessThanOrEqualTo(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.Id + " <=", value, "id");

            return this;
        }

        public Criteria andIdLessThanOrEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.Id);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdLessThanOrEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.Id + " <= ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdIn(long[] values) {
            if (values.length == 1) {
                return andIdEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.Id + " in", values, "id");

                return this;
            }
        }

        public Criteria andIdNotIn(long[] values) {
            if (values.length == 1) {
                return andIdNotEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.Id + " not in", values, "id");

                return this;
            }
        }

        public Criteria andIdIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andIdEqualTo(values.get(0));
            } else {
                addCriterion(ISysUserPhotoDAO.Id + " in", values, "id");

                return this;
            }
        }

        public Criteria andIdNotIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andIdNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysUserPhotoDAO.Id + " not in", values, "id");

                return this;
            }
        }

        public Criteria andIdIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andIdEqualTo(values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.Id + " in",
                    Arrays.asList(values), "id");

                return this;
            }
        }

        public Criteria andIdNotIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andIdNotEqualTo(values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.Id + " not in",
                    Arrays.asList(values), "id");

                return this;
            }
        }

        public Criteria andIdIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.Id + " in ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.Id + " not in ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdBetween(long value1, long value2) {
            addCriterion(ISysUserPhotoDAO.Id + " between", value1, value2, "id");

            return this;
        }

        public Criteria andIdBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysUserPhotoDAO.Id + " between", value1, value2, "id");

            return this;
        }

        public Criteria andIdNotBetween(long value1, long value2) {
            addCriterion(ISysUserPhotoDAO.Id + " not between", value1, value2,
                "id");

            return this;
        }

        public Criteria andIdNotBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysUserPhotoDAO.Id + " not between", value1, value2,
                "id");

            return this;
        }

        public Criteria andUserIdIsNull() {
            addCriterion(ISysUserPhotoDAO.UserId + " is null");

            return this;
        }

        public Criteria andUserIdIsNotNull() {
            addCriterion(ISysUserPhotoDAO.UserId + " is not null");

            return this;
        }

        public Criteria andUserIdIsNotEmpty() {
            addCriterion(ISysUserPhotoDAO.UserId + " is not null AND " +
                ISysUserPhotoDAO.UserId + " <> ''");

            return this;
        }

        public Criteria andUserIdIsEmpty() {
            addCriterion("(" + ISysUserPhotoDAO.UserId + " is null OR " +
                ISysUserPhotoDAO.UserId + " = '')");

            return this;
        }

        public Criteria andUserIdEqualTo(long value) {
            return andUserIdEqualTo(Long.valueOf(value));
        }

        public Criteria andUserIdEqualTo(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.UserId + " = ", value, "userId");

            return this;
        }

        public Criteria andUserIdEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserId);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserIdEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserId + " = ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserIdNotEqualTo(long value) {
            return andUserIdNotEqualTo(Long.valueOf(value));
        }

        public Criteria andUserIdNotEqualTo(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.UserId + " <>", value, "userId");

            return this;
        }

        public Criteria andUserIdNotEqualToOrIsNull(long value) {
            return andUserIdNotEqualToOrIsNull(Long.valueOf(value));
        }

        public Criteria andUserIdNotEqualToOrIsNull(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.UserId + " is null OR " +
                ISysUserPhotoDAO.UserId + " <>", value, "userId");

            return this;
        }

        public Criteria andUserIdNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserId);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserIdNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserId + " <> ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserIdGreaterThan(long value) {
            return andUserIdGreaterThan(Long.valueOf(value));
        }

        public Criteria andUserIdGreaterThan(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.UserId + " >", value, "userId");

            return this;
        }

        public Criteria andUserIdGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserId);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserIdGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserId + " > ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserIdGreaterThanOrEqualTo(long value) {
            return andUserIdGreaterThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andUserIdGreaterThanOrEqualTo(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.UserId + " >=", value, "userId");

            return this;
        }

        public Criteria andUserIdGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserId);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserIdGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserId + " >= ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserIdLessThan(long value) {
            return andUserIdLessThan(Long.valueOf(value));
        }

        public Criteria andUserIdLessThan(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.UserId + " <", value, "userId");

            return this;
        }

        public Criteria andUserIdLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserId);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserIdLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserId + " < ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserIdLessThanOrEqualTo(long value) {
            return andUserIdLessThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andUserIdLessThanOrEqualTo(java.lang.Long value) {
            addCriterion(ISysUserPhotoDAO.UserId + " <=", value, "userId");

            return this;
        }

        public Criteria andUserIdLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserId);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserIdLessThanOrEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserId + " <= ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserIdIn(long[] values) {
            if (values.length == 1) {
                return andUserIdEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.UserId + " in", values, "userId");

                return this;
            }
        }

        public Criteria andUserIdNotIn(long[] values) {
            if (values.length == 1) {
                return andUserIdNotEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.UserId + " not in", values,
                    "userId");

                return this;
            }
        }

        public Criteria andUserIdIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andUserIdEqualTo(values.get(0));
            } else {
                addCriterion(ISysUserPhotoDAO.UserId + " in", values, "userId");

                return this;
            }
        }

        public Criteria andUserIdNotIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andUserIdNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysUserPhotoDAO.UserId + " not in", values,
                    "userId");

                return this;
            }
        }

        public Criteria andUserIdIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andUserIdEqualTo(values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.UserId + " in",
                    Arrays.asList(values), "userId");

                return this;
            }
        }

        public Criteria andUserIdNotIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andUserIdNotEqualTo(values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.UserId + " not in",
                    Arrays.asList(values), "userId");

                return this;
            }
        }

        public Criteria andUserIdIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserId + " in ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserIdNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserId + " not in ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserIdBetween(long value1, long value2) {
            addCriterion(ISysUserPhotoDAO.UserId + " between", value1, value2,
                "userId");

            return this;
        }

        public Criteria andUserIdBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysUserPhotoDAO.UserId + " between", value1, value2,
                "userId");

            return this;
        }

        public Criteria andUserIdNotBetween(long value1, long value2) {
            addCriterion(ISysUserPhotoDAO.UserId + " not between", value1,
                value2, "userId");

            return this;
        }

        public Criteria andUserIdNotBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysUserPhotoDAO.UserId + " not between", value1,
                value2, "userId");

            return this;
        }

        public Criteria andUserPhotoIsNull() {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " is null");

            return this;
        }

        public Criteria andUserPhotoIsNotNull() {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " is not null");

            return this;
        }

        public Criteria andUserPhotoIsNotEmpty() {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " is not null AND " +
                ISysUserPhotoDAO.UserPhoto + " <> ''");

            return this;
        }

        public Criteria andUserPhotoIsEmpty() {
            addCriterion("(" + ISysUserPhotoDAO.UserPhoto + " is null OR " +
                ISysUserPhotoDAO.UserPhoto + " = '')");

            return this;
        }

        public Criteria andUserPhotoEqualTo(String value) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " = ", value, "userPhoto");

            return this;
        }

        public Criteria andUserPhotoEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserPhoto);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserPhotoEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " = ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserPhotoNotEqualTo(String value) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " <>", value, "userPhoto");

            return this;
        }

        public Criteria andUserPhotoNotEqualToOrIsNull(String value) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " is null OR " +
                ISysUserPhotoDAO.UserPhoto + " <>", value, "userPhoto");

            return this;
        }

        public Criteria andUserPhotoNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserPhoto);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserPhotoNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " <> ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserPhotoGreaterThan(String value) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " >", value, "userPhoto");

            return this;
        }

        public Criteria andUserPhotoGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserPhoto);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserPhotoGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " > ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserPhotoGreaterThanOrEqualTo(String value) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " >=", value, "userPhoto");

            return this;
        }

        public Criteria andUserPhotoGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserPhoto);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserPhotoGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " >= ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserPhotoLessThan(String value) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " <", value, "userPhoto");

            return this;
        }

        public Criteria andUserPhotoLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserPhoto);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserPhotoLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " < ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserPhotoLessThanOrEqualTo(String value) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " <=", value, "userPhoto");

            return this;
        }

        public Criteria andUserPhotoLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysUserPhotoDAO.UserPhoto);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andUserPhotoLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " <= ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserPhotoLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysUserPhotoDAO.UserPhoto + " like",
                buffer.toString(), "userPhoto");

            return this;
        }

        public Criteria andUserPhotoNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysUserPhotoDAO.UserPhoto + " not like",
                buffer.toString(), "userPhoto");

            return this;
        }

        public Criteria andUserPhotoIn(List<String> values) {
            if (values.size() == 1) {
                return andUserPhotoEqualTo(values.get(0));
            } else {
                addCriterion(ISysUserPhotoDAO.UserPhoto + " in", values,
                    "userPhoto");

                return this;
            }
        }

        public Criteria andUserPhotoNotIn(List<String> values) {
            if (values.size() == 1) {
                return andUserPhotoNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysUserPhotoDAO.UserPhoto + " not in", values,
                    "userPhoto");

                return this;
            }
        }

        public Criteria andUserPhotoIn(String[] values) {
            if (values.length == 1) {
                return andUserPhotoEqualTo(values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.UserPhoto + " in",
                    Arrays.asList(values), "userPhoto");

                return this;
            }
        }

        public Criteria andUserPhotoNotIn(String[] values) {
            if (values.length == 1) {
                return andUserPhotoNotEqualTo(values[0]);
            } else {
                addCriterion(ISysUserPhotoDAO.UserPhoto + " not in",
                    Arrays.asList(values), "userPhoto");

                return this;
            }
        }

        public Criteria andUserPhotoIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " in ", subQueryBean, dao);

            return this;
        }

        public Criteria andUserPhotoNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " not in ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andUserPhotoBetween(String value1, String value2) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " between", value1,
                value2, "userPhoto");

            return this;
        }

        public Criteria andUserPhotoNotBetween(String value1, String value2) {
            addCriterion(ISysUserPhotoDAO.UserPhoto + " not between", value1,
                value2, "userPhoto");

            return this;
        }
    }
}
